package org.car.world.wx.api.AbstractFactory.service;

public class AbstractFactoryTest {
 public static void main(String[] args) {
	
	 AbstractFactory ab1 =  FactoryProducer.getfactory("SHAPE");
	 
	 Shape sh1 = ab1.getShape("CIRCLE");
	 sh1.draw();
	 
	 Shape sh2 = ab1.getShape("RECTANGLE");
	 sh2.draw();
	 
	 Shape sh3= ab1.getShape("SQUARE");
	 sh3.draw();
	 
	 
	 AbstractFactory ab2 =  FactoryProducer.getfactory("COLOR");
	 
	 Color c1 = ab2.getColor("RED");
	 c1.fill();
	 
	 Color c2 = ab2.getColor("BLUE");
	 c2.fill();
	 
	 Color c3 = ab2.getColor("GREEN");
	 c3.fill();
	 
	 
}
}
